# 导包
import requests
# 创建类
class IhirLogin(object):
    # 创建类方法
    @classmethod
    def login(cls,requests_json):
        # 登录接口
        resp = requests.post(url='http://ihrm-test.itheima.net/api/sys/login',
                             json=requests_json)
        return resp
if __name__ == '__main__':
    json_data= {"mobile": "13800000002", "password": "123456"}
    resp = IhirLogin.login(json_data)
    print(resp.json())
